<template>
  <router-view v-slot="{ Component }">
      <keep-alive :include="pages">
          <component :is="Component" />
      </keep-alive>
  </router-view>
</template>
<script>
export default {
    computed: {
        pages() {
            return this.$store.state.pages
        }
    },
    watch: {
        pages(v) {
            console.log(v)
        }
    }
}
</script>

